/*----------------------------------------------------------------------------*/
/* Copyright (c) FIRST 2008. All Rights Reserved.							  */
/* Open Source Software - may be modified and shared by FRC teams. The code   */
/* must be accompanied by the FIRST BSD license file in $(WIND_BASE)/WPILib.  */
/*----------------------------------------------------------------------------*/
#ifndef TASK_H
#define TASK_H


/**
 * WPI task is a wrapper for the native Task object.
 * All WPI tasks are managed by a static task manager for simplified cleanup.
 **/
class Task {

public:
	
	Task(char* name, int priority );
	virtual ~Task();
	
	bool  Run(FUNCPTR function, int arg);
	bool  Restart();
	bool  Delete();
	
	bool  Suspend();
	bool  Resume();
	
	bool  Verify();
	
	int   GetPriority();
	void  SetPriority(int p);
	char* GetName();
	int   GetID();

private:
	char* m_taskName;
	int m_taskID;
	int m_priority;
	
	
};

#endif
